Java Locks: Analysis and Acceleration by
نویسنده
چکیده
This dissertation presents several techniques to accelerate Java locks based on the analyses of their behavior from various viewpoints. Ten years have passed since Java was announced, and now the language has come to be used in various fields including large-scale Web services. To make such applications practical, performance improvements for the Java execution environments are indispensable. In Java, the language directly supports parallel processing, and lock operations are executed very frequently. Their overhead is considerable. For example, one report said that 1/5 of the execution time was consumed by lock processing in an early Java environment. Therefore, accelerating Java locks has been very important to make Java environments run faster. From the analysis of locks in various Java applications, we discovered that most contentions are temporary in Java. To exploit this contention transience, this dissertation presents a new method for Java locks, in which a lock can be acquired with just one atomic operation in the absence of contention. The method, called tasuki lock, increased the performance of Java application by up to 13.1%, and is used by IBM’s production Java virtual machines. Next, uncontended Java locks were also analyzed, and it turned out that for many objects, the lock is acquired primarily by a specific thread. By exploiting the thread locality, this dissertation proposes a novel technique of reserving locks for threads. With the reservation lock, the reservation-owner thread can acquire a lock without any atomic operations, and the performance was further improved by up to 53%. This dissertation also presents an improvement of the reservation lock, where the reservation is not canceled and the owner thread can always acquire its locks very quickly. In this asymmetric lock, we observed a performance improvement of up to 7.9%. A unique methodology for introducing a new feature into Java locks is also used in this algorithm. The main contributions of this dissertation are: the findings about new characteristics of Java locks, the proposals of new lock methods that exploit these characteristics, and their implementation and evaluation on a state-of-the-art Java system.
منابع مشابه
Abstraction and Verification of Properties of a Real-Time Java
ion and Verification of Properties of a Real-Time Java Nadezhda Baklanova and Martin Strecker IRIT (Institut de Recherche en Informatique de Toulouse) Université de Toulouse 118 route de Narbonne, F-31062 Toulouse CEDEX 9, France [email protected], [email protected] Abstract. We present a tool for analysing resource sharing conflicts in multithreaded Java programs. Java programs ...
متن کاملSafe Locking for Multi-threaded Java
There are many mechanisms for concurrency control in high-level programming languages. In Java, the original mechanism for concurrency control, based on synchronized blocks, is lexically scoped. For more flexible control, Java 5 introduced non-lexical operators, supporting lock primitives on re-entrant locks. These operators may lead to run-time errors and unwanted behavior; e.g., taking a lock...
متن کاملSafe locking for multi-threaded Java with exceptions
There are many mechanisms for concurrency control in high-level programming languages. In Java, the original mechanism for concurrency control, based on synchronized blocks, is lexically scoped. For more flexible control, Java 5 introduced non-lexical lock primitives on re-entrant locks. These operators may lead to runtime errors and unwanted behavior; e.g., taking a lock without releasing it, ...
متن کاملFast Multi-Level Locks for Java A Preliminary Performance Evaluation
Atomic sections guarantee atomic and isolated execution of a block of code. Transactional Memory can be used to implement them but suffers from the inability to support system calls and has high overhead. Lock inference is a pessimistic alternative that infers the locks necessary to prevent thread interference. Our research looks at lock inference techniques for Java programs. An important aspe...
متن کاملSpecial Issue on Java Technologies for Real-Time and Embedded Systems JTRES2013
The first paper [2] discusses software locking mechanisms that commonly protect shared resources for multi-threaded applications. This mechanism can, especially in chip-multiprocessor systems, result in a large synchronization overhead. For real-time systems in particular, this overhead increases the worstcase execution time and may void a task set's schedulability. This paper presents two hard...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2005